<?php 
    $modelAdvertise = new Default_Model_Advertise();
    $advertiseList = $modelAdvertise->getDataVisible();                
?>
<div id="slider-carousel" class="carousel slide" data-ride="carousel">
	<ol class="carousel-indicators">
    <?php 
        $i=0;
        foreach($advertiseList as $ad){
            if($i == 0)
                echo '<li data-target="#slider-carousel" data-slide-to="'.$i++.'" class="active"></li>';
            else
                echo '<li data-target="#slider-carousel" data-slide-to="'.$i++.'"></li>';
        }
    ?>		
	</ol>
	
	<div class="carousel-inner">
    <?php 
        $i=0;
        foreach($advertiseList as $ad){
            if($i == 0){
    ?>
        <div class="item active">
        	<div class="col-sm-6">
        		<h1><span>E</span>-SHOPPER</h1>
        		<h2><?=$ad['title']?></h2>
        		<p><?=$ad['description']?></p>
        		<a href="auth"><button type="button" class="btn btn-default get">Get it now</button></a>
        	</div>
        	<div class="col-sm-6">
        		<img src="/static/default/images/home/girl1.jpg" class="girl img-responsive" alt="" />
        		<img src="/static/default/images/home/pricing.png"  class="pricing" alt="" />
        	</div>
        </div>
    <?php
            }else{
    ?>
        <div class="item">
        	<div class="col-sm-6">
        		<h1><span>E</span>-SHOPPER</h1>
        		<h2><?=$ad['title']?></h2>
        		<p><?=$ad['description']?></p>
        		<a href="auth"><button type="button" class="btn btn-default get">Get it now</button></a>
        	</div>
        	<div class="col-sm-6">
        		<img src="/static/default/images/home/girl2.jpg" class="girl img-responsive" alt="" />
        		<img src="/static/default/images/home/pricing.png"  class="pricing" alt="" />
        	</div>
        </div>  
    <?php
                      
            }   
            $i++;                      
        }
    ?>	                                                                                                            							
	</div>
	
	<a href="#slider-carousel" class="left control-carousel hidden-xs" data-slide="prev">
		<i class="fa fa-angle-left"></i>
	</a>
	<a href="#slider-carousel" class="right control-carousel hidden-xs" data-slide="next">
		<i class="fa fa-angle-right"></i>
	</a>
</div>